package com.chengdu.third.service.Impl;

import com.chengdu.third.dao.IZwxxDao;
import com.chengdu.third.pojo.Zwxx;
import com.chengdu.third.service.IZwxxService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author jingbo
 * @create 2021--08--15  22:01
 */

@Service
public class IZwxxServiceImpl implements IZwxxService {

    @Autowired
    private IZwxxDao iZwxxDao;

    @Override
    public List<Zwxx> findAll() {
        return iZwxxDao.find();
    }


    @Override
    public List<Zwxx> findByRec1() {
        return iZwxxDao.findByRec1();
    }

    @Override
    public List<Zwxx> findByRec2() {
        return iZwxxDao.findByRec2();
    }

    @Override
    public List<Zwxx> findByRec3() {
        return iZwxxDao.findByRec3();
    }

    @Override
    public List<Zwxx> findByRec4() {
        return iZwxxDao.findByRec4();
    }

    @Override
    public void deleteByid(long id) {
       iZwxxDao.delete(id);
    }

    @Override
    public void updateByid(Zwxx zwxx) {
       iZwxxDao.update(zwxx);
    }

    @Override
    public void addzwxx(Zwxx zwxx) {
       iZwxxDao.add(zwxx);
    }

    @Override
    public Zwxx getZwxxById(long id) {
        return iZwxxDao.getZwxxById(id);
    }
}
